package com.sky.controller.user;

import com.sky.entity.UserReadingData;
import com.sky.result.Result;
import com.sky.service.impl.UserReadingDataServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/user/user-reading-data")
public class UserReadingDataController {
    @Autowired
    private UserReadingDataServiceImpl userReadingDataService;

    /**
     * 获取用户阅读数据
     * @return
     */
    @GetMapping("")
    public Result getReadingData() {
        UserReadingData userReadingData = userReadingDataService.getUserReadingData();
        return Result.success(userReadingData);
    }
}